<!-- directive:title 自动代码生成1.5版本 接口文档生成 -->
<!-- directive:breadcrumb 自动化1.5 -->
<!-- 表单 -->
<div class="panel-body">
    <table class="table">
        <tbody>
            <tr>
                <td>
                    接口标题 <input type="text" placeholder="" style="width:250px;" ng-model="fromObj.api.title">
                    接口URL <input type="text" placeholder="" style="width:250px;" ng-model="fromObj.api.url">
                </td>
            </tr>
            <tr ng-repeat="row in fromObj.requestColume track by $index">
                <td>
                    字段 <input type="text" placeholder="字段" style="width:250px;text-align:center;" ng-model="row.title">
                    注释 <input type="text" placeholder="注释" style="width:250px;text-align:center;" ng-model="row.note">
                    类型 <select placeholder="类型" style="width:50px;" ng-model="row.type">
                        <option value="文本">文本</option>
                        <option value="数字">数字</option>
                        <option value="数组">数组</option>
                        <option value="对象">对象</option>
                        <option value="对象数组">对象数组</option>
                    </select>
                    出入 <select placeholder="出入" style="width:50px;" ng-model="row.isInOut">
                        <option value="in">入参</option>
                        <option value="out">出参</option>
                    </select>
                    是否必填<input type="checkbox" ng-model="row.required">
                    <span style="color:#F44336;" ng-click="removeItem('requestColume', $index)"> <i class="fa fa-close"></i> </span>
                    增加子属性<span style="color:#4CAF50;" ng-click="addSubItem(row.sub)"> <i class="fa fa-plus"></i> </span>
                    <div style=" margin-left: 400px; background: #8BC34A; ">
                        <div ng-repeat="row2 in row.sub track by $index">
                            字段 <input type="text" placeholder="字段" style="width:150px;text-align:center;" ng-model="row2.title">
                            注释 <input type="text" placeholder="注释" style="width:150px;text-align:center;" ng-model="row2.note">
                            <span style="color:#F44336;" ng-click="addSubItem(row.sub, $index)"> <i class="fa fa-close"></i> </span>
                        </div>
                    </div>
                </td>
            </tr>
            <tr>
                <td>
                    添加参数 <span ng-click="addItem('requestColume')" style="color:#4CAF50;"> <i class="fa fa-plus"></i> </span>
                </td>
            </tr>
        </tbody>
    </table>
    <button class="btn btn-success" ng-click="makeApiCode()"> <i class="glyphicon glyphicon-plus"></i>生产接口说明 </button>
    <button class="btn btn-danger" ng-click="printFromObj()"> 打印当前 json </button>
    <button class="btn btn-success" ng-click="getFromObj()"> 接收 console/localstorage 中的 json </button>
    <pre id="templateA"></pre>
</div>
